Skip to content

Comments

feat(dgw): generate self-signed certificate when no TLS cert is configured for CredSSP#1682

Merged
Benoît Cortier (CBenoit) merged 6 commits intomasterfrom
fix/generate-self-signed-certificate-for-credssp
Feb 20, 2026
Merged

feat(dgw): generate self-signed certificate when no TLS cert is configured for CredSSP#1682
Benoît Cortier (CBenoit) merged 6 commits intomasterfrom
fix/generate-self-signed-certificate-for-credssp

Conversation

@CBenoit
Copy link
Member

When neither a CredSSP-specific certificate nor a main TLS certificate is configured, automatically generate a self-signed certificate for CredSSP credential injection.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request enhances the Devolutions Gateway to automatically generate a self-signed TLS certificate for CredSSP credential injection when neither a CredSSP-specific certificate nor a main TLS certificate is configured. Previously, the gateway would fail with an error when attempting credential injection without a configured TLS certificate. Now, it gracefully handles this scenario by generating a minimal self-signed certificate on-the-fly.

Changes:

  • Added automatic self-signed certificate generation for CredSSP when no TLS certificate is configured
  • Replaced optional TLS requirement checks with a dedicated non-optional credssp_tls field in the configuration
  • Implemented certificate generation using RSA 2048-bit keys with a 2-year validity period

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
devolutions-gateway/src/config.rs Added credssp_tls field to Conf struct; implemented generate_self_signed_certificate() function; added logic to initialize credssp_tls by either cloning existing TLS config or generating a new self-signed certificate
devolutions-gateway/src/rdp_proxy.rs Changed to use conf.credssp_tls instead of requiring main TLS configuration
devolutions-gateway/src/rd_clean_path.rs Changed to use conf.credssp_tls instead of requiring main TLS configuration

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

…gured for CredSSP

When neither a CredSSP-specific certificate nor a main TLS certificate
is configured, automatically generate a self-signed certificate for
CredSSP credential injection.
@CBenoit Benoît Cortier (CBenoit) force-pushed the fix/generate-self-signed-certificate-for-credssp branch from b2f8388 to 0e72a4b Compare February 19, 2026 11:22
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@CBenoit Benoît Cortier (CBenoit) merged commit e4a1b12 into master Feb 20, 2026
40 checks passed
@CBenoit Benoît Cortier (CBenoit) deleted the fix/generate-self-signed-certificate-for-credssp branch February 20, 2026 13:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants